From 1a5dc16c668394d2205e3b2b42fbeb8df54398e0 Mon Sep 17 00:00:00 2001 From: "cl349@firebug.cl.cam.ac.uk" Date: Wed, 15 Feb 2006 14:13:10 +0000 Subject: [PATCH] Cleanup x86/x86_64 apic.c files. Signed-off-by: Christian Limpach --- .../arch/i386/kernel/apic-xen.c | 16 ++++++----- .../arch/x86_64/kernel/apic-xen.c | 28 +++++++++---------- .../drivers/xen/core/smpboot.c | 5 ++-- 3 files changed, 25 insertions(+), 24 deletions(-) diff --git a/linux-2.6-xen-sparse/arch/i386/kernel/apic-xen.c b/linux-2.6-xen-sparse/arch/i386/kernel/apic-xen.c index 5ba0be371a..bee39abf96 100644 --- a/linux-2.6-xen-sparse/arch/i386/kernel/apic-xen.c +++ b/linux-2.6-xen-sparse/arch/i386/kernel/apic-xen.c @@ -60,11 +60,6 @@ int enable_local_apic __initdata = 0; /* -1=force-disable, +1=force-enable */ */ int apic_verbosity; -int get_physical_broadcast(void) -{ - return 0xff; -} - /* * 'what should we do if we get a hw irq event on an illegal vector'. * each architecture has to answer this themselves. @@ -83,12 +78,19 @@ void ack_bad_irq(unsigned int irq) ack_APIC_irq(); } +int get_physical_broadcast(void) +{ + return 0xff; +} + #ifdef CONFIG_XEN void switch_APIC_timer_to_ipi(void *cpumask) { } EXPORT_SYMBOL(switch_APIC_timer_to_ipi); void switch_ipi_to_APIC_timer(void *cpumask) { } EXPORT_SYMBOL(switch_ipi_to_APIC_timer); -#else +#endif + +#ifndef CONFIG_XEN #ifndef CONFIG_SMP static void up_apic_timer_interrupt_call(struct pt_regs *regs) { @@ -120,12 +122,12 @@ void smp_send_timer_broadcast_ipi(struct pt_regs *regs) #endif } } +#endif int setup_profiling_timer(unsigned int multiplier) { return -EINVAL; } -#endif /* * This initializes the IO-APIC and APIC hardware if this is diff --git a/linux-2.6-xen-sparse/arch/x86_64/kernel/apic-xen.c b/linux-2.6-xen-sparse/arch/x86_64/kernel/apic-xen.c index d82b568b4f..66a432a32c 100644 --- a/linux-2.6-xen-sparse/arch/x86_64/kernel/apic-xen.c +++ b/linux-2.6-xen-sparse/arch/x86_64/kernel/apic-xen.c @@ -36,11 +36,19 @@ #include #include -/* - * Debug level - */ int apic_verbosity; -int disable_apic; + +#ifdef CONFIG_XEN +void switch_APIC_timer_to_ipi(void *cpumask) { } +EXPORT_SYMBOL(switch_APIC_timer_to_ipi); +void switch_ipi_to_APIC_timer(void *cpumask) { } +EXPORT_SYMBOL(switch_ipi_to_APIC_timer); +#endif + +int setup_profiling_timer(unsigned int multiplier) +{ + return -EINVAL; +} void smp_local_timer_interrupt(struct pt_regs *regs) { @@ -159,17 +167,7 @@ asmlinkage void smp_error_interrupt(void) irq_exit(); } -int get_physical_broadcast(void) -{ - return 0xff; -} - -#ifdef CONFIG_XEN -void switch_APIC_timer_to_ipi(void *cpumask) { } -EXPORT_SYMBOL(switch_APIC_timer_to_ipi); -void switch_ipi_to_APIC_timer(void *cpumask) { } -EXPORT_SYMBOL(switch_ipi_to_APIC_timer); -#endif +int disable_apic; /* * This initializes the IO-APIC and APIC hardware if this is diff --git a/linux-2.6-xen-sparse/drivers/xen/core/smpboot.c b/linux-2.6-xen-sparse/drivers/xen/core/smpboot.c index 8f057f9f7c..4c72930e86 100644 --- a/linux-2.6-xen-sparse/drivers/xen/core/smpboot.c +++ b/linux-2.6-xen-sparse/drivers/xen/core/smpboot.c @@ -432,11 +432,12 @@ void __init smp_cpus_done(unsigned int max_cpus) { } +#ifndef CONFIG_X86_LOCAL_APIC int setup_profiling_timer(unsigned int multiplier) { - /* Dummy function. */ - return 0; + return -EINVAL; } +#endif /* * Local variables: -- 2.30.2